Displacement sensor having a display data output

ABSTRACT

Provided is a displacement sensor which allows at least part of the data used from the time of obtaining an image until the time of computing the displacement can be readily verified. In a displacement sensor for automatically extracting a coordinate of a measuring point from an image obtained by using an imaging device according to a prescribed measuring point extraction algorithm, and computing a desired displacement from the automatically extracted measuring point coordinate, the sensor is further provided with the function to edit data used from the time of obtaining the image until the time of computing the displacement for use as display data for an image monitor.

TECHNICAL FIELD

The present invention relates to a displacement sensor for measuring adisplacement such as a dimension of an object according to a lightsection image or the like.

BACKGROUND OF THE INVENTION

The displacement sensor for measuring a displacement such as a dimensionof an object according to a light section image (image obtained by usinga light section method) is known in the art. Typically, a displacementsensor of this type automatically extracts a coordinate of a measuringpoint from an image obtained by using an imaging device in a sensor headaccording to a prescribed measuring point extraction algorithm, andcomputes a desired displacement from the automatically extractedmeasuring point coordinate.

The sensor head is incorporated with a laser diode for emitting a spotbeam (beam having an extremely small circular cross section) or a linebeam (beam having a linear cross section), and an imaging device(one-dimensional CCD, two-dimensional CCD or the like) for monitoring aregion containing a radiation point of the beam from a different angle,and producing an image containing a variation corresponding to adisplacement of the monitored object.

The main unit automatically extracts a measuring point coordinate fromthe image obtained from each sensor head according to a measuring pointextraction algorithm designated by the user. Then, the actualdisplacement is computed from the automatically extracted measuringpoint coordinate by using a triangular computation or the like. If arange of variation tolerance (threshold value) is defined for thedisplacement, a tolerance determination process is performed, and abinary signal indicating the acceptability of the object can beobtained.

According to such a conventional displacement sensor, if the measuringpoint extraction algorithm or the like is designated in advance, ameasuring point coordinate can be automatically extracted from the imageobtained, and the desired displacement can be computed in the end sothat no effort is required for the user.

However, it does not provided any means for verifying the data (such asthe raw image from the imaging device, the automatically extractedmeasuring point coordinate and various automatically defined thresholdvalues or the like) which is used during the entire process of obtainingthe image and computing the displacement.

Therefore, when the measured displacement turns out to be abnormal orwhen an unacceptable measurement result is obtained, it is not possibleto distinguish for the user if it is due to the abnormal condition ofthe object or due to the abnormal operation of the sensor, possibly dueto the influences of external light or the like.

Furthermore, the conventional displacement sensor is not capable ofdefining the field of view of the imaging device at will, for example,to extract a measuring point at will. This is a particularly significantproblem of a displacement sensor with two-dimensional imaging devices(such as two-dimensional CCD or the like). Specifically, because, innormal cases, there are a plurality (typically in the order of tens) ofcolumns of pixels extending in the direction of the displacement in amutually parallel relationship, the need for finding a peak point and abottom point from each of these columns creates a serious difficultywhen implementing the sensor as a commercial product.

BRIEF SUMMARY OF THE INVENTION

In view of such problems of the prior art, a primary object of thepresent invention is to provide such a displacement sensor which is easyto use.

A more specific object of the present invention is to provide adisplacement sensor which allows the data used from the time ofobtaining the image until the time of computing the displacement to beeasily verified.

A more specific object of the present invention is to provide adisplacement sensor which allows the filed of view of the imaging deviceto be selected, and the measuring point to be extracted at will.

These and other objects and effects of the present invention will becomemore apparent to a person skilled in the art from the followingdescription.

The present invention provides a displacement sensor for automaticallyextracting a coordinate of a measuring point from an image obtained byusing an imaging device according to a prescribed measuring pointextraction algorithm, and computing a desired displacement from theautomatically extracted measuring point coordinate.

The “imaging device” means any imaging device which has a plurality ofpixels in the direction of displacement measurement, and allows theaddress of each light receiving position corresponding to a displacementto be identified. Therefore, imaging devices such as PSD which would notallow the address of each light receiving position to be identified areexcluded from the concept of the present invention. The imaging deviceas used herein include one-dimensional CCDs and two-dimensional CCDsamong other possibilities.

The “measuring point extraction algorithm” may comprise any one of anumber of known algorithms. Such known algorithms may include peak valuesearching algorithms, bottom value searching algorithms, average valuesearching algorithms and most proximate value searching algorithms,among other possibilities.

The “measuring point coordinate” means coordinate data on which thecomputation of the displacement is based. This coordinate data can bedetermined at the precision level of pixels or sub-pixels. When theimaging device consists of a two-dimensional imaging device, eachmeasuring point coordinate will have a two-dimensional value. However,the basis for the displacement computation will be typically found inthe coordinate values in the direction of the displacement.

The “automatic extraction” means that there is no human intervention.However, it does not exclude the possibility of dialog processes such asthe one inquiring the user of the selection of modes during the courseof extracting the measuring point coordinate.

The “computation formula based on a measuring point coordinate” may varydepending on the optical arrangement of the sensor head. It typicallyconsists of obtaining a displacement from a measuring point coordinateaccording to the principle of triangulation.

The output from the displacement sensor is not limited to the computeddisplacement data as can be readily appreciated. For instance, athreshold level for a tolerable range may be designated by the user sothat the determination result indicating if the particular product isacceptable or not may be produced.

In addition to the above mentioned structure, the displacement sensor ofthe present invention may comprise display data editing means forediting the data used from the time of obtaining the image until thetime of computing the displacement for use as display data for an imagemonitor.

The “data used from the time of obtaining the image until the time ofcomputing the displacement” may include any conceivable data such as theraw image obtained by the imaging device, the automatically extractedmeasuring point coordinate and various threshold values that areautomatically defined, as well as data of other kinds that can beautomatically and erroneously defined due to external light or the likebecause of the automatic nature of the algorithm.

The “display data editing means” implies that the image monitor is notan indispensable element of the displacement sensor of the presentinvention. In other words, it suffices for the displacement sensor ofthe present invention to be provided with display data editing means.The displacement sensor of the present invention may be originallyprovided with an image monitor as an integral part thereof, or,alternatively, it may be optionally fitted with a commercially availableimage monitor when such a need arises.

According to the present invention having the above described structure,the data used from the time of obtaining the image until the time ofcomputing the displacement can be readily verified via the display onthe image monitor, and it allows any abnormal value of the measureddisplacement to be distinguished if the object for measurement is indeedabnormal or if it is a result of the abnormal operation of the sensordue to external light or the like.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to a raw image obtainedby the imaging device.

The “raw image” as used herein means an image of an object to bemeasured which is obtained by the imaging device.

According to this structure, it is possible to readily verify where onthe surface of the object to be measured the measuring light (sectionlight) is being impinged, if external light is being impinged upon thesurface of the object to be measured, and how much is the brightness ofthe illuminating light image of the measuring light.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to a raw image obtainedby the imaging device, and a graphic image indicating a coordinate of ameasuring point placed over the raw image.

According to this structure, by comparing the image such as a markindicating the automatically extracted measuring point with the image ofthe surface of the object to be measured one over the other, one canreadily verify if the measuring point has been properly determined at aposition on which the measuring light impinges, or if the measuringpoint has been improperly determined at a position on which externallight impinges.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to a raw image obtainedby the imaging device, and a graphic image indicating a measurementvalue tolerance range in the direction of displacement measurement shownover the raw image.

According to this structure, by showing the graphic image such as aboundary line indicating the measurement tolerance range and the imageof the surface of the object to be measured one over the other, one canreadily verify the relationship between the position of the illuminatinglight image of the measuring light and the measurement tolerance range.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to a raw image obtainedby the imaging device, and a graphic image indicating a coordinate of ameasuring point and a measurement value tolerance range in the directionof displacement measurement shown over the raw image.

According to this structure, by comparing the graphic image such as aboundary line indicating the measurement tolerance range and the graphicimage such as a mark indicating the automatically extracted coordinateof the measuring point with the image of the surface of the object to bemeasured, one can readily verify the relationship between theautomatically extracted measuring point coordinate, the position of theilluminating light image of the measuring light and the measurementtolerance range.

According to a preferred embodiment of the present invention, the imagedisplayed on the image monitor according to the display data can beexpanded in the direction of displacement measurement.

According to this structure, one can verify the relationship between theautomatically extracted measuring point coordinate, the measurementvalue tolerance range and the image of the surface of the object to bemeasured even more closely.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to the image of a linebright waveform.

The “line bright waveform” means a curve which indicates thedistribution of the brightness of the received light along the row ofpixels. For instance, it can be represented in a graph having thedisplacement on the abscissa and the brightness of the received light(gradation) on the ordinate.

According to this structure, the distribution of the brightness alongthe direction of displacement measurement on the surface of the objectto be measured can be verified in an accurate manner.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to the line brightwaveform and a graphic image indicating a measuring point coordinateshown over the line bright waveform.

According to this structure, by comparing the line bright waveform andthe measuring point coordinate, one can readily verify if the measuringpoint is properly determined on the spot which is illuminated by themeasuring light and if the measuring point is improperly determined onthe spot which is illuminated by external light.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to the line brightwaveform and a graphic image indicating a threshold value for extractingthe measuring point coordinate shown over the line bright waveform.

According to this structure, by comparing the peak of the line brightwaveform and the graphic image such as a line indicating a thresholdvalue, one can verify the process of automatically extracting themeasuring point coordinate. If the automatically extracted measuringpoint coordinate is displayed at the same time, one can verify if themeasuring point extraction algorithm has been properly executed or not.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to the line brightwaveform and a graphic image indicating a measurement value tolerancerange in the direction of displacement measurement.

According to this structure, by comparing the peak of the line brightwaveform with the graphic image such as a boundary line indicating themeasurement tolerance range, one can verify the process of determiningthe acceptability of each product.

According to a preferred embodiment of the present invention, thedisplay data on the image monitor corresponds to the line brightwaveform and graphic images indicating a measuring point coordinate anda measurement value tolerance range in the direction of displacementmeasurement shown over the line bright waveform.

According to this structure, by comparing the graphic image such as amark for indicating the automatically extracted measuring point and thegraphic image such as a boundary line indicating the measurement valuetolerance range with the line bright waveform, one can readily verifythe relationship between the peak of the line bright waveform, theautomatically extracted measuring point coordinate, and the measurementvalue tolerance range.

According to a preferred embodiment of the present invention, the imagedisplayed on the image monitor according to the display data can beenlarged in the direction for displacement measurement.

According to this structure, one can verify the relationship between theautomatically extracted measuring point coordinate, the measurementvalue tolerance range, and the line bright of the surface of the objectto be measured even more closely.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to a raw image obtainedby the imaging device and the line bright waveform which are shown oneover the other or one next to the other.

According to this structure, one can readily verify the relationshipbetween the visually observed distribution of the brightness on thesurface of the object to be measured with the distribution of thebrightness on the surface of the object to be measured as represented bythe peak of the line bright waveform.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to an image combining theraw image obtained from the imaging device and the line bright waveformwhich are placed one next to the other or one over the other, and thecombined image additionally combines an image indicating a measuringpoint coordinate shown over the raw image and/or the line brightwaveform.

According to this structure, one can verify the process of automaticallyextracting the measuring point coordinate by using both the image of thesurface of the object to be measured and the line bright waveform.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to an image combining theraw image obtained from the imaging device and the line bright waveformwhich are placed one next to the other or one over the other, and thecombined image additionally combines an image indicating a tolerancerange for a measurement value in a direction for measuring thedisplacement shown over the raw image and/or the line bright waveform.

According to this structure, one can verify the process of determiningthe acceptability of each product by using both the image of the surfaceof the object to be measured and the line bright waveform.

According to a preferred embodiment of the present invention, thedisplay data for the image monitor corresponds to an image combining theraw image obtained from the imaging device and the line bright waveformwhich are placed one next to the other or one over the other, and thecombined image additionally combines an image indicating a measuringpoint coordinate and an image indicating a tolerance range for ameasurement value in a direction for measuring the displacement shownover the raw image and/or the line bright waveform.

According to this structure, one can verify the process of automaticallyextracting the measuring point coordinate and the process of determiningthe acceptability of each product by using both the image of the surfaceof the object to be measured and the line bright waveform.

According to a preferred embodiment of the present invention, the imagedisplayed on the image monitor according to the display data can beenlarged in the direction for displacement measurement.

According to this structure, one can verify the process of automaticallyextracting the measuring point coordinate and the process of determiningthe acceptability of each product more precisely by using both the imageof the surface of the object to be measured and the line brightwaveform.

According to a preferred embodiment of the present invention, the imagedisplayed on the image monitor according to the display data correspondsto a raw image obtained from the imaging device and a graphic imageindicating a measuring point extracting range defined in a directionperpendicular to the direction of displacement measurement which isplaced over the raw image.

According to this structure, one can verify the contents of themeasuring point extracting algorithm by comparing the image of thesurface of the object to be measured with the graphic image such as aboundary line defining the range of extracting the measuring point.

According to a preferred embodiment of the present invention, the imagedisplayed on the image monitor according to the display data correspondsto a raw image obtained from the imaging device and a graphic imageindicating a measuring point extracting range defined in a directionperpendicular to the direction of displacement measurement and anautomatically extracted measuring point coordinate which are placed overthe raw image.

According to this structure, one can verify if the measuring pointextracting algorithm has been properly executed by comparing the imageof the surface of the object to be measured with the graphic image suchas a boundary line defining the range of extracting the measuring pointand the graphic image indicating the automatically extracted measuringpoint coordinate.

According to a preferred embodiment of the present invention, the imagedisplayed on the image monitor according to the display data correspondsto a trend graph image which shows computed displacements in a timesequence.

According to this structure, one can identify the increasing ordecreasing trend of the currently measuring values by comparing the timehistory of a series of measured values included in the trend graph.

According to another aspect of the present invention, the presentinvention provides a displacement sensor for automatically extracting acoordinate of a measuring point from an image obtained by using animaging device according to a prescribed measuring point extractionalgorithm, and computing a desired displacement from the automaticallyextracted measuring point coordinate, further comprising: means fordefining a measuring point extraction range on the image obtained by theimaging device; and means for automatically extracting a measuring pointcoordinate from a part of the image within the measuring pointextraction range according to a prescribed measuring point extractionalgorithm.

According to a preferred embodiment of the present invention, themeasuring point extraction range is defined in the direction fordisplacement measurement.

According to a preferred embodiment of the present invention, theimaging device consists of a two-dimensional imaging device, and themeasuring point extraction range is defined in a direction perpendicularto the direction for displacement measurement.

According to this structure, because the range for extracting themeasuring point can be defined over the image obtained from the imagingdevice, improper extraction due to external light can be avoided.Furthermore, when a two-dimensional imaging device is used, by limingthe width of the columns of pixels for measurement to a minimum value,the time required for extracting the measuring point can be minimized.

According to this structure, the convenience of the displacement sensorconsisting of a two-dimensional imaging device can be improved.Specifically, because, typically, a plurality (typically tens or more)of columns of pixels extend in the direction of displacement in parallelwith one another, the need for extracting a peak point and a bottompoint from each column would make the sensor system highly inconvenientto use.

According to another aspect of the present invention, the presentinvention provides a displacement sensor, comprising: one or a pluralityof sensor head each incorporated with a light source for generating alight section beam and an imaging device for imaging an object to bemeasured which is illuminated by the light section beam; a main unitconnected to the sensor head or the sensor heads with an electric cord;a console unit formed integrally with or separately from the main unitfor supplying various commands to the main unit; and an image monitordriven by a monitor output obtained from the main unit; the main unitbeing adapted to automatically extract a coordinate of a measuring pointfrom an image obtained by the sensor head or sensor heads by using aprescribed measuring point extraction algorithm.

The main unit is further adapted to compute a displacement according tothe automatically extracted coordinate of the measuring point; the mainunit further comprising display data editing means for editing data usedfrom the time of obtaining the image until the time of computing thedisplacement for use as display data for the image monitor.

According to a preferred embodiment of the present invention, the lightsection beam consists of a line beam, and the imaging device consists ofa two-dimensional imaging device.

According to a preferred embodiment of the present invention, the mainunit further comprises means for defining a measuring range on the imageobtained by the sensor head according to a prescribed manipulation of acontrol variable, and means for automatically extracting a coordinate ofa measuring point from the image in the measuring range according to aprescribed measuring point extracting algorithm.

According to this structure, the improper operation due to theinfluences of external light and improper adjustment of various partscan be avoided, and a highly convenient displacement sensor can beprovided.

BRIEF DESCRIPTION OF THE DRAWINGS

Now the present invention is described in the following with referenceto the appended drawings, in which:

FIG. 1 is a block diagram showing an exemplary displacement systemstructure embodying the present invention;

FIG. 2 is an illustrative view showing the outline of the internalstructure of the sensor head;

FIG. 3 is a block diagram of the internal structure of the main unit;

FIG. 4 is a general flow chart schematically showing the process ofmeasuring a displacement by using the displacement sensor;

FIG. 5 is an illustrative view showing an image obtained by using theCCD in the sensor head;

FIG. 6 is an illustrative view showing the process of extracting themeasuring point in the measuring range;

FIG. 7 is an illustrative view showing the relationship between an imageobtained by the CCD and the corresponding line bright waveform;

FIG. 8 is an illustrative view showing the process of determining thethreshold value;

FIG. 9 is an illustrative view showing the process of extracting themeasuring point coordinate;

FIG. 10 is an illustrative view showing the process of generating themonitor display;

FIG. 11 is a view showing an exemplary monitor display when a normalmeasurement result is obtained;

FIG. 12 is an illustrative view showing an exemplary monitor displaywhen the image and the line bright waveform are enlarged in thedirection of displacement measurement;

FIG. 13 is an illustrative view showing an exemplary monitor displaywhen an abnormal measurement result is obtained due to externaldisturbances;

FIG. 14 is an illustrative view showing an exemplary monitor displaywhen a step measurement is conducted by using two sensors at the sametime;

FIG. 15 is a view showing an exemplary monitor display when displacementdata is shown in a time sequence;

FIG. 16 is an illustrative view showing an exemplary monitor displaywhen a sensor head selection is being conducted;

FIG. 17 is an illustrative view showing an exemplary monitor displaywhen the start point of the measuring range in the beam line directionis being determined;

FIG. 18 is an illustrative view showing an exemplary monitor displaywhen the end point of the measuring range in the beam line direction isbeing determined;

FIG. 19 is an illustrative view showing an exemplary monitor displaywhen the measuring point of the measuring range in the beam linedirection is being extracted (normal mode);

FIG. 20 is an illustrative view showing an exemplary monitor displaywhen the measuring point of the measuring range in the beam linedirection is being extracted (peak mode);

FIG. 21 is an illustrative view showing an exemplary monitor displaywhen the measuring point of the measuring range in the beam linedirection is being extracted (bottom mode);

FIG. 22 is an illustrative view showing an exemplary monitor displaywhen the measuring point on the line bright is being extracted; and

FIG. 23 is an illustrative view showing an exemplary monitor displaywhen the measuring point on the line bright is being extracted.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

As mentioned earlier, the displacement sensor of the present inventionconsists of a displacement sensor for automatically extracting acoordinate of a measuring point from an image obtained by using animaging device according to a prescribed measuring point extractionalgorithm, and computing a desired displacement from the automaticallyextracted measuring point coordinate, characterized by that: the sensorfurther comprises display data editing means for editing data used fromthe time of obtaining the image until the time of computing thedisplacement for use as display data for an image monitor.

FIG. 1 shows a block diagram of the structure of a displacement sensorembodying the present invention.

As shown in the drawing, this displacement sensor 1 comprises a mainunit 10, a pair of sensor heads 20A and 20B, an image monitor 30 and aconsole unit 40. The reference numeral 50 denotes external equipmentsuch as PLC. The main unit 10 is a central part of the displacementsensor, and essentially consists of a microprocessor. The main unit 10is internally incorporated with various processing functions by usingsoftware as described in the following with reference to FIG. 3.

The sensor heads 20A and 20B each detect a displacement and convert itinto information on a position on a light receiving surface. Anexemplary sensor head 20A or 20B is shown in FIG. 2. As shown in thedrawing, the sensor head 20A or 20B comprises a laser diode 201 foremitting laser light, a slit plate 202 placed in front of the laserdiode 201, a lens system 203 for focusing the laser light which haspassed through the slit plate 202 and impinging onto an object 60 to bedetected, and an imaging device 205 for capturing the image obtainedfrom the object 60 via a lens system 204.

The slit of the slit plate 202 is linear so that the light beam whichimpinges upon the object 60 consists of a line beam (beam having alinear cross section). In this example, the axial direction (directionperpendicular to the cross section of the line beam) of the line beam isperpendicular to the sheet of the paper.

The imaging device 205 in this case consists of a two-dimensional CCDdevice. In particular, this two-dimensional CCD device has a field ofview in the shape of an elongated rectangle. For example, the lightreceiving surface of the CCD device has 1077 pixels along the long side,and 68 pixels along the short side. The direction of the line beamimpinging upon the light receiving surface extends in a directionperpendicular to the long side of the light receiving surface of the CCDdevice.

Referring to FIG. 1 once again, the console unit 40 is adapted to beportable, and is provided with up and down keys (not shown in thedrawing) as well as numeric keys and function keys. The console unit 40is connected to the main unit 10 via an electric cord.

The image monitor 30 receives a monitor output (display data) from themain unit 10, and displays a corresponding image on its screen. Theimage monitor 30 may consist of any commercially available monitors suchas CRT displays and LCDs.

The external equipment 50 corresponds to a programable controller (PLC)or the like, and receives a displacement data output D1 and adetermination result output D2 from the main unit 10. The main unit 10is a central part of the present invention which automatically extractsa measuring point coordinate from the image obtained by the sensor head20A or 20B according to a measuring point extraction algorithmdesignated by the user, computes the actual displacement from theautomatically extracted measuring point coordinate by using atriangulation computation or the like, and, if a tolerance range(threshold value) for the displacement is defined, executes a tolerancerange determination process, for producing a binary signal whichindicates if the object is acceptable or not. The obtained displacementdata output D1 and determination result output D2 consisting of a binarysignal are forwarded to the external equipment 50.

FIG. 3 shows a block diagram representing the internal functionalstructure of the main unit. As shown in the drawing, the main unitessentially consists of a measurement unit 110 and a control unit 120.The measurement unit 110 comprises an interface unit 111 for the sensorheads and an image computing unit 112 for processing the image dataobtained from the sensor heads 20A and 20B via the interface unit 111.

The control unit 120 is incorporated with a GUI unit 121 serving as aninterface for the image monitor 30 and console unit 40, an imageprocessing unit 122 for suitably processing the image data obtained fromthe measurement unit 110 and forwarding the image data to the GUI unit121, an external output interface 124 for forwarding the displacementdata output D1 and determination result output D2 which were mentionedearlier to the external equipment, and a control processing unit 123 forgenerally controlling the overall system.

The data flow in this system is described in the following. A sensorhead control unit 111B incorporated in the interface unit 111 controlsthe intensity of the light emitted from the laser diode 201 (see FIG. 2)so as to suitably adjust the amount of the light received by the CCDsincorporated in the sensor heads 20A and 20B. At the same time, theimage data D3 obtained by the CCDs of the sensor heads 20A and 20B isforwarded to the measurement unit 110 under the action of an imagecapturing unit 111A.

The image data forwarded to the measurement unit 110 is then forwardedto an image transfer unit 112A and a measurement processing unit 112B inthe image computing unit 112. The image transfer unit 112A forwards theimage data D3 received from the image capturing unit 111A to the imageprocessing unit 122 of the control unit 120.

The process of extracting the measurement point coordinate and theprocess of measuring the displacement which are essential features ofthe present invention are achieved mainly by this measurement processingunit 112B.

The control processing unit 123 in the control unit 120 computes themeasuring point coordinate (in the direction of the line beam) data D8from the data D7 received from the measurement processing unit 112B, andforwards it to the image processing unit 112. The image processing unit122 forwards data D4 including both image data and line bright data tothe GUI unit 121. The GUI unit 121 receives various commands from theconsole unit 40, and edits the display data which is then forwarded tothe image monitor 30 as a monitor output D5.

The process of editing the display data which is an essential feature ofthe present invention is achieved mainly by this image process unit 122and the GUI (graphic user interface) unit 121.

The mode of operation of the displacement sensor described above inmeasuring the displacement is now described in the following withreference to the flow chart of FIG. 4. Referring to this drawing, in thefirst step, the image obtained by the CCDs in the sensor heads is fed tothe main unit (step 401).

The image obtained by the CCDs in the sensor heads is illustrated inFIG. 5. As shown in the drawing, the CCD in each sensor head has a fieldof view 71 in the shape of an elongated rectangle. The X directionextending along the long side of this field of view corresponds to thedisplacement direction, and the Y direction extending along the shortside corresponds to the direction of the line beam. The field of view 71of the sensor includes an image 72 of the line beam (image of theilluminating light) in a zigzag shape. In terms of the direction ofdisplacement, the left side in the drawing corresponds to the directionnearer to the sensor head and the right side corresponds to thedirection farther from the sensor head.

Referring to FIG. 4 once again, characteristic points in the range ofmeasurement are extracted (step 402). The process of extracting ameasuring point in the range of measurement is illustrated in FIG. 6. Asshown in the drawing, a measuring range 73 is indicated in the field ofview 71 of the sensor by a pair of dotted lines 74 and 75 which extendlaterally across the field in parallel to each other. In this process ofextracting a measuring point, by using a prescribed algorithm forextracting characteristic points from this range of measurement(measurement point extraction range) 73, a peak position (Px, Py) and abottom position (Bx, By) are extracted. As discussed later, the startpoint line 74 and the end point line 75 defining the range ofmeasurement 73 (measurement point extraction range) are designated bythe user.

Referring to FIG. 4, the line bright of the line containing thecharacteristic points is extracted in the following step (step 403). Therelationship between the image obtained by the CCD and the line brightwaveform is illustrated in FIG. 7. As shown in this drawing, during theprocess of extracting the line bright, the brightness of the receivedlight for each pixel on the line containing the peak position isextracted as indicated by the chain dot line, and the line brightwaveform 76 shown in the drawing is generated by arranging the receivedlight brightness for each pixel along the direction of displacement. Asshown in FIG. 7, the line brightness waveform 76 is shown in theorthogonal coordinate system having the displacement on the abscissaaxis and the gradation on the ordinate axis.

Referring to FIG. 4, the measuring point coordinate on the line brightis extracted according to the prescribed extraction algorithm in thefollowing step (step 404). The process of extracting the measuring pointcoordinate is conducted via the processes of determining a thresholdvalue and extracting the measuring point coordinate. An exemplary methodof determining a threshold value is illustrated in FIG. 8. As shown inthe drawing, the threshold value TH is determined as a percentile ratioa% with respect to the brightness Vp of the pixel PP demonstrating thepeak value. In other words, it is automatically determined by theformula TH=Vp×a%. The process of extracting the measuring pointcoordinate is illustrated in FIG. 9. There are three modes available forthe process of extracting a measuring point coordinate, or the areacentroid method, edge center method and side edge method. As shown inFIG. 9( a), according to the area centroid method, the measuring pointis obtained as the centroid of the gradation area exceeding thethreshold value TH. According to the edge center mode, the measuringpoint is determined as the center of two points obtained as theintersections between the line bright waveform and the threshold levelTH. According to the side edge mode, the measuring point is obtained asan intersection between a side edge of the line bright waveform with thethreshold level TH.

Referring to FIG. 4 once again, the displacement is computed from themeasured coordinate (step 405). For instance, when the optical system isbased on the triangulation, this displacement computing process producesthe displacement according to the formula (displacement Z)=A×B/(C×X),where X is the coordinate in the direction of the displacement, and A, Band C are constants that are determined by the optical system.

Referring to FIG. 4 once again, the obtained displacement (or adetermination result if necessary) is forwarded to the image monitor 30and the external equipment 50 (step 406). The determination resultaccording to a reference value designated by the user is conducted asdescribed in the following.

The determination result is HIGH when the displacement is larger thanthe HIGH reference value.

The determination result is PASS when HIGH reference value ≧displacement ≧ LOW reference value (the object is found acceptable).

The determination result is LOW when the displacement is smaller thanthe LOW reference value.

The determination result is ERROR when the sensor is unable to measure.

The process of generating the images on the monitor display isillustrated in FIG. 10. As shown in this drawing, four image memoryblocks (layers) (0) to (3) are used. Image memory block (0) stores theraw image obtained from the sensor heads, image memory block (1) storesframe determination values and fixed image components, image memoryblock (2) stores a line bright waveform and a measuring point, and imagememory block (3) stores a displacement value and determinationreferences. The data in these memory blocks is read out in a parallelrelationship by the action of the GUI unit 121 and the image processingunit 122, and forwarded to the image monitor 30 as a monitor output(display data) D5.

Examples of a display on the image monitor 30 are described in thefollowing with reference to FIGS. 11 to 15.

FIG. 11 shows an example of a monitor display when a normal measurementvalue has been obtained. In this example, as shown in FIG. 11( b), thereference distance between the sensor head and the object to be measuredis 100 mm, and the displacement is measured over a range extending by 20mm from this reference distance in each direction. As shown in FIG. 11(a), the frame of the monitor is divided into four areas arranged in thevertical direction. These areas include an image display area 77, graphdisplay area 78, number display area 79 and guide display area 80, fromtop to bottom.

The image display area 77 displays a raw image (gradation image)obtained from the imaging device consisting of a two-dimensional CCD. Inthe drawing, the reference numeral 81 denotes a line beam image, and thereference numeral 82 denotes a cross symbol for indicating the measuringpoint coordinate on the raw image.

The graph display area 78 displays the line bright waveform along withvertical and horizontal grid lines. The reference numeral 83 denotes theline bright waveform, and the reference numeral 84 denotes the verticaland horizontal grid lines. The two dotted lines extending in thevertical direction are determination reference values for LOW and HIGH.

The number display area 79 shows a number indicating the displacement,and a symbol indicating the determination result. In the drawing, thenumeral 88 denotes a value (+101.5345) indicating the measured value,and the numeral 89 denotes a symbol (PASS) indicating the determinationresult.

FIG. 12 illustrates an example of a monitor display with the image andline bright waveform enlarged in the direction of the displacement. Inthis drawing, the parts corresponding to those of FIG. 11 are denotedwith like numerals without repeating the description of such parts. Asshown in the drawing, the raw image on the image display area 77 and theline bright waveform 83 in the graph display 78 area are bothsubstantially enlarged in the direction of measuring the displacement.For this reason, the image of the line beam denoted by numeral 81appears to be circular, instead of being shown as linear. By enlargingthe display of the raw image and line bright waveform in this manner,the relationship of the measuring point coordinate with the raw imageand line bright waveform can be indicated clearly, and is thereforeallowed to be verified in a highly accurate manner.

FIG. 13 illustrates an example of a monitor display when an error hasoccurred in the measurement due to external disturbances. In thisdrawing, the parts corresponding to those of FIG. 11 are denoted withlike numerals without repeating the description of such parts. In thisexample, although the light image 81 of the normal line beam stayswithin a prescribed range, and the determination result is LOW whichindicates an unacceptable product as denoted by numeral 89. As for theraw image in the image display area 77, the light image due to externallight appears below the lower limit value as denoted by numeral 90, andthe cross symbol as denoted by numeral 82 indicating the measuring pointcoordinate falls on this false light image 90. Likewise, in the graphdisplay area 78, although the true peak of the line bright curve 83falls within the acceptable range, the peak due to external disturbancesis located below the lower limit value. It can be seen that the crosssymbol as denoted by numeral 85 indicating the measuring pointcoordinate is located on this peak value which is due to external light.From this display, the user can see that the erroneous measurement wasmade due to the false light image 90 due to external light, instead ofan actual abnormal displacement in the product.

FIG. 14 illustrates an example of a monitor display when a step is to bemeasured by using two sensor heads at the same time. In this drawing,the parts corresponding to those of FIG. 11 are denoted with likenumerals without repeating the description of such parts. In thisexample, as shown in FIG. 14( b), the two sensor heads (0) and (1) areplaced opposite to the object to the measured, and are adapted tomeasure the respective distances and automatically compute thedifference (step) between the two distances. As shown in FIG. 14( a), inthis instance, a number (+4.5345) indicating the step is displayed onthe number display area 79 as denoted by numeral 88. The image displayarea is divided into two parts one on top of the other, and the upperpart shows the raw image associated with the sensor head (0) while thelower part shows the raw image associated with the sensor head (1). Thelight images 81 a and 82 a corresponding to the line beams and the crosssymbols 81 b and 82 b indicating the measuring point coordinates aredisplayed on these raw images, respectively. The graph display area 78shows the line bright waveforms 83 a and 83 b and cross symbols 85 a and85 b corresponding to the sensor heads (0) and (1), respectively.Therefore, according to the image display described above, in case ofany abnormal situation, one can readily discover which of the sensorheads (0) or (1) has failed. The symbol (PASS) for the determinationresult denoted with numeral 89 corresponds to the acceptable range forthe step.

FIG. 15 shows an example of a monitor display when the displacement datais to be displayed in a time sequence. In this drawing, the partscorresponding to those of FIG. 11 are denoted with like numerals withoutrepeating the description of such parts. In this example, as shown inFIG. 15( a), the distance between each component part A or B transportedon a belt conveyor and the sensor head is measured one after another,and the result is displayed on the graph display area as a time sequencewaveform (trend graph) 91 as shown in FIG. 15( a). The light image 81 ofthe light beam and the cross symbol 82 indicating the measuring pointcoordinate at each time point are displayed on the image display area77. According to this display, the variations of the dimensions of thecomponents A, B can be measured in a clear manner, and the measurementprocess can be conducted in a highly smooth manner.

The process of defining the measuring range 73 which was described inconnection with the previously described exemplary measurement processis now more fully described. As mentioned earlier, the two sensors 20Aand 20B are connected to the system in this embodiment. Also, as shownin FIG. 14, a step can be measured by using the two sensorssimultaneously. As one can readily appreciate, each of the sensor headscan be selected and adjusted individually.

FIG. 16 illustrates the monitor display when selecting one of the sensorheads. In this drawing, the parts corresponding to those of FIG. 11 aredenoted with like numerals without repeating the description of suchparts. A dialog box 92 is opened by acting upon the console unit 40which is connected to the system main body, and either one of thesensors heads 20A or 20B can be selected by conducting a suitableoperation.

FIG. 17 illustrates a monitor display when the start point for the rangeof measurement in the direction of the beam line is to be defined. Inthis drawing, the parts corresponding to those of FIG. 11 arc denotedwith like numerals without repeating the description of such parts.During the process of selecting the range of measurement, the startpoint line 92 and end point line 93 are drawn in the image display area77 as indicated by the dotted lines extending horizontally in thedrawing. These lines 92 and 93 can be moved vertically as atranslational motion on the monitor by conducting a suitable operation.When determining the start point line 92, the cursor 94 is placed on thestart point line (A) 92 by a suitable operation. The start point line 92is placed on a desired pixel position in this state, and the start pointline 92 can be placed at a desired position by conducting a suitableoperation. In the drawing, the start point line 92 is placed on the 16thpixel.

FIG. 18 illustrates a monitor display when the end point for the rangeof measurement in the direction of the beam line is to be defined. Inthis drawing, the parts corresponding to those of FIG. 11 are denotedwith like numerals without repeating the description of such parts. Whenplacing the end point line 93 at a desired location, the cursor 94 isplaced on the end point line (B) 93 and the end point line (B) 93 ismoved vertically until the desired position is reached by conducting asuitable operation. In this example, the end point line 93 is placed onthe 40th pixel. During this process, the positions of the start pointline 92 and end point line 93 are displayed on the number display area79. Thus, the measuring range (measuring range extraction range) 95 isdefined between the 16th pixel and 40th pixel.

The process of extracting characteristic points (measuring point) in themeasuring range according to three different modes (normal mode, peakmode and bottom mode) following the process of defining the measuringrange is described in the following.

FIG. 19 illustrates a monitor display (normal mode) when the measuringpoint in the range of measurement in the direction of the beam line isbeing extracted. In this drawing, the parts corresponding to those ofFIG. 11 are denoted with like numerals without repeating the descriptionof such parts. As shown in the drawing, an image 96 of the line beamhaving a flat peak and a flat bottom is shown on the image display area77. In the normal mode, the measuring point is automatically definedbetween the peak position and bottom position. The cross symbol (cursor)denoted by numeral 97 indicates the position of the measuring point. Inthe normal mode, the measuring point is thus automatically determinedbetween the peak position and bottom position within the measuring rangelocated between the 16th pixel and 40th pixel.

FIG. 20 illustrates a monitor display (peak mode) when the measuringpoint in the range of measurement in the direction of the beam line isbeing extracted. In this drawing, the parts corresponding to those ofFIG. 11 are denoted with like numerals without repeating the descriptionof such parts. As shown in the drawing, an image 96 of the line beamhaving a flat peak and a flat bottom is shown on the image display area77. In the peak mode, the measuring point is defined at the peakposition. The cross symbol (cursor) denoted by numeral 97 indicates theposition of the measuring point. In the peak mode, the measuring pointis thus automatically determined at the peak position within themeasuring range located between the 16th pixel and 40th pixel.

FIG. 21 illustrates a monitor display (bottom mode) when the measuringpoint in the range of measurement in the direction of the beam line isbeing extracted. In this drawing, the parts corresponding to those ofFIG. 11 are denoted with like numerals without repeating the descriptionof such parts. As shown in the drawing, an image 96 of the line beamhaving a flat peak and a flat bottom are shown on the image display area77. In the bottom mode, the measuring point is defined at the bottomposition. The cross symbol (cursor) denoted by numeral 97 indicates theposition of the measuring point. In the bottom mode, the measuring pointis thus automatically determined at the bottom position within themeasuring range located between the 16th pixel and 40th pixel.

FIG. 22 illustrates a monitor display when the measuring point on theline bright is being extracted. In this drawing, the parts correspondingto those of FIG. 11 are denoted with like numerals without repeating thedescription of such parts. As shown in the drawing, the line brightwaveform is drawn in the graph display area 78, and the cursor 98indicating the measuring point coordinate is displayed at a pointadjacent to the peak position. The cursors 97 and 98 may be aligned witheach other on a vertical line. According to this arrangement, bycomparing the image display area 77 and graph display area 78, themeasuring point can be even more accurately verified.

FIG. 23 illustrates a monitor display when the measuring point on theline bright is being extracted. In this drawing, the parts correspondingto those of FIG. 11 are denoted with like numerals without repeating thedescription of such parts. As can be appreciated by comparing the graphdisplay area (normal size) 78 and the graph display area (enlarged size)78′, the line bright waveform is enlarged in the direction of measuringthe displacement in this example. As a result, the line bright waveformdisplayed in the graph display area (enlarged size) 78′ allows therelationship between the measuring point coordinate and the line brightwaveform to be verified even better. This operation can be enabled byselecting the enlarged mode after verifying the measuring pointcoordinate in the graph display area (normal size) 78.

As can be appreciated from the foregoing description, this displacementsensor enables the user not only to verify the result of displacementmeasurement but also to display various items of data (raw image, linebright waveform and various threshold values) which are used from thetime the raw image is obtained until the time the displacement ismeasured on the monitor screen. Therefore, even when an abnormaldisplacement measurement result is obtained, one can readily determineif it is due to the abnormal state of the object to be measured or dueto the faulty operation of the system caused by external light, andappropriate measures against such situations can be taken without anydelay, for instance when applied to a production line.

In particular, because the raw image and line bright waveform are placedone next to the other on the monitor screen, if an abnormal measurementresult is produced due to external light, one can readily discover thecause in an accurate manner by comparing the raw image with the linebright waveform.

Also, because the measuring range is defined not only in the directionof displacement measurement but also in the perpendicular direction,when the image of the line beam is offset in the field of view of thetwo-dimensional CCD or the measuring point on the object to be measuredis offset in the field of view of the CCD, it is possible to more finelydefine the measuring point by taking into account such an offsetting,and this contributes to an even more accurate displacement measurement.

It is also possible to display the two outputs from the two sensorswhich operate at the same time on the monitor screen one over the otheror one next to the other. Therefore, when a step is desired to bemeasured by using the two sensor heads, even in case of an error, it canbe immediately and accurately determined which of the sensors is faulty.

When a plurality of objects are carried by a belt conveyor, thedisplacement of each object can be displayed on the monitor screen in atime sequence, and this feature is highly convenient for use in atesting process in a production line.

As can be appreciated from the foregoing description, according to thepresent invention, the data which is used from the time the raw image isobtained until the time the displacement is computed can be easilyverified. Therefore, when the measured displacement is found to beabnormal, it can be determined if the object to be measured is indeedabnormal or if it is due to the faulty operation of the sensor due toexternal light. Also, according to the present invention, the measuringpoint can be extracted by freely limiting the field of view of theimaging device. Thus, according to the present invention, theconvenience of such a displacement sensor can be substantially enhanced.

Although the present invention has been described in terms of preferredembodiments thereof, it is obvious to a person skilled in the art thatvarious alterations and modifications are possible without departingfrom the scope of the present invention which is set forth in theappended claims.

1. A displacement sensor for automatically extracting a coordinate of ameasuring point from an image obtained by using an imaging deviceaccording to a prescribed measuring point extraction algorithm, andcomputing a desired displacement from the automatically extractedmeasuring point coordinate, characterized by that: the sensor furthercomprises display data editing means for editing at least part of dataused from the time of obtaining the image until the time of computingthe displacement for use as display data for an image monitor, andwherein the display data for the image monitor comprises a raw imageobtained by the imaging device.
 2. A displacement sensor according toclaim 1, wherein the display data for the image monitor furthercomprises a graphic image indicating a measuring point coordinate whichis shown in association with the raw image.
 3. A displacement sensoraccording to claim 1, wherein the display data for the image monitorfurther comprises a graphic image indicating a tolerance range for ameasurement value in a direction for measuring the displacement which isshown in association with the raw image.
 4. A displacement sensoraccording to claim 1, wherein the display data for the image monitorfurther comprises a graphic image indicating a measuring pointcoordinate and a tolerance range for a measurement value in a directionfor measuring the displacement which are shown in association with theraw image.
 5. A displacement sensor according to claim 1, wherein theediting means is adapted to enlarge an image based on the display datain the direction for displacement measurement.
 6. A displacement sensorfor automatically extracting a coordinate of a measuring point from animage obtained by using an imaging device according to a prescribedmeasuring point extraction algorithm, and computing a desireddisplacement from the automatically extracted measuring pointcoordinate, characterized by that: the sensor further comprises displaydata editing means for editing at least part of data used from the timeof obtaining the image until the time of computing the displacement foruse as display data for an image monitor, and wherein the display datacomprises an image of a line bright waveform obtained from a raw image.7. A displacement sensor according to claim 6, wherein the display datafurther comprises a graphic image indicating a measuring pointcoordinate shown in association with the line bright waveform.
 8. Adisplacement sensor according to claim 6, wherein the display datafurther comprises a graphic image indicating a threshold level forextracting the measuring point coordinate shown in association with theline bright waveform.
 9. A displacement sensor according to claim 6,wherein the display data further comprises a graphic image indicating atolerance range for a measurement value in a direction for measuring thedisplacement which is shown in association with the line brightwaveform.
 10. A displacement sensor according to claim 6, wherein thedisplay data further comprises a graphic image indicating a measuringpoint coordinate and a tolerance range for a measurement value in adirection for measuring the displacement which is shown in associationwith the line bright waveform.
 11. A displacement sensor according toclaim 6, wherein the editing means is adapted to enlarge an image basedon the display data in the direction for displacement measurement.
 12. Adisplacement sensor for automatically extracting a coordinate of ameasuring point from an image obtained by using an imaging deviceaccording to a prescribed measuring point extraction algorithm, andcomputing a desired displacement from the automatically extractedmeasuring point coordinate, characterized by that: the sensor furthercomprises display data editing means for editing at least part of dataused from the time of obtaining the image until the time of computingthe displacement for use as display data for an image monitor, andwherein the display data for the image monitor comprises a raw imageobtained from the imaging device and a line bright waveform obtainedfrom the raw image for display on a monitor in a prescribedrelationship.
 13. A displacement sensor according to claim 12, whereinthe display data further comprises a graphic image indicating ameasuring point coordinate shown in association with the raw imageand/or the line bright waveform.
 14. A displacement sensor according toclaim 12, wherein the display data further comprises a graphic imageindicating a tolerance range for a measurement value in a direction formeasuring the displacement shown in association with the raw imageand/or the line bright waveform.
 15. A displacement sensor according toclaim 12, wherein the display data further comprises a graphic imageindicating a measuring point coordinate and a tolerance range for ameasurement value in a direction for measuring the displacement inassociation with the raw image and/or the line bright waveform.
 16. Adisplacement sensor according to claim 12, wherein the editing means isadapted to enlarge an image based on the display data in the directionfor displacement measurement.
 17. A displacement sensor according toclaim 1, wherein the display data further comprises a graphic imageindicating a measuring point extracting range defined in a directionperpendicular to the direction of displacement measurement which isshown in association with the raw image.
 18. A displacement sensoraccording to claim 1, wherein the display data further comprises agraphic image indicating a measuring point extracting range defined in adirection perpendicular to the direction of displacement measurement andan automatically extracted measuring point coordinate which is shown inassociation with the raw image.
 19. A displacement sensor forautomatically extracting a coordinate of a measuring point from an imageobtained by using an imaging device according to a prescribed measuringpoint extraction algorithm, and computing a desired displacement fromthe automatically extracted measuring point coordinate, characterized bythat: the sensor further comprises display data editing means forediting at least part of data used from the time of obtaining the imageuntil the time of computing the displacement for use as display data foran image monitor, and wherein the display data comprises a trend graphimage showing a plurality of computed displacements in a time sequence.